import Vue from 'vue'
import VueRouter from 'vue-router'

import Login from '../views/Login'
import Register from '../views/Register'
import Layout from '@/views/Layout'
Vue.use(VueRouter)

const routes = [{
  path: '/',
  component: Layout
}, {
  path: '/register',
  component: Register
}, {
  path: '/login',
  component: Login
}]

const router = new VueRouter({
  mode: 'hash',
  // base: process.env.BASE_URL,// 路由的基地址
  routes
})

export default router
